/**
 *
 */
package cn.dw.mm.service.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import cn.dw.mm.service.ProblemService;
import cn.dw.mm.domain.Problem;
import cn.dw.mm.mapper.ProblemsMapper;

@Service
public class ProblemServiceImpl implements ProblemService {
	
	@Autowired
	private ProblemsMapper problemsMapper;

	@Override
	public List<Problem> selectByProblemId(Integer id) {
		return problemsMapper.selectByProblemId(id);
	}

	@Override
	public List<Problem> selectByCondiction(Problem problem) {
		return problemsMapper.selectByCondiction(problem);
	}
	
	@Override
	public int deleteById(Integer id) {
		return problemsMapper.deleteById(id);
	}

	@Override
	public int insert(Problem problem) {
		return problemsMapper.insert(problem);
	}

	@Override
	public int update(Problem problem) {
		return problemsMapper.update(problem);
	}
}
